<!DOCTYPE html><html><head><title>Ext.dd.Registry | Ext JS 4.0 Documentation</title><script type="text/javascript" src="../ext-all.js"></script><link rel="stylesheet" href="../reset.css" type="text/css"><link rel="stylesheet" href="../scrollbars.css" type="text/css"><link rel="stylesheet" href="../docs.css" type="text/css"><link id="styleCss" rel="stylesheet" href="../style.css" type="text/css"><script type="text/javascript" src="../prettify.js"></script><link rel="stylesheet" href="../prettify.css" type="text/css"><!-- link(rel: 'stylesheet', href: req.baseURL + '/css/ext4.css', type: 'text/css')--><link rel="shortcut icon" type="image/ico" href="../favicon.ico"><!--[if IE]>
<style type="text/css">.head-band { display: none; }
.header { border: 0; top: 0; left: 0px; background: url(../header.gif) repeat-x; }
.doc-tab .members .member a.more { background-color: #efefef; }
</style><link rel="stylesheet" href="/new/css/ie.css" type="text/css"><![endif]-->
</head><body id="ext-body" class="iScroll"><div id="notice" class="notice">For up to date documentation and features, visit 
<a href="http://docs.sencha.com/ext-js/4-0">http://docs.sencha.com/ext-js/4-0</a></div><div class="wrapper"><div class="head-band"></div><div class="header"><h2><a href="../index.html">Sencha Documentation</a></h2></div><div id="search"><form><input type="text" placeholder="Search" id="search-field" autocomplete="off" name="q"></form><div id="search-box"></div></div><div id="treePanel"></div><div id="container"><script type="text/javascript">

    req = {
        liveURL: '.',
        standAloneMode: true,
        origDocClass: 'Ext.dd.Registry',
        docClass: 'Ext.dd.Registry',
        docReq: 'Ext.dd.Registry',
        version: '4.0',
        baseURL: '.',
        baseDocURL: '.',
        baseProdURL: '.'
    };

    clsInfo = {};



</script>

<script type="text/javascript" src="../search.js"></script>
<!--script type="text/javascript" src="/new/javascripts/app/examples.js"></script-->
<script type="text/javascript" src="../class_tree.js"></script>
<script type="text/javascript" src="../class_doc.js"></script>
<script type="text/javascript">
    req.source = 'Registry.html#Ext-dd.Registry';
    clsInfo = {"methods":["getHandle","getHandleFromEvent","getTarget","getTargetFromEvent","register","unregister"],"cfgs":[],"properties":[],"events":[],"subclasses":[]};
    Ext.onReady(function() {
        Ext.create('Docs.classPanel');
    });
</script><div id="top-block" class="top-block"><h1 id="clsTitle" class="cls"><a href="../source/Registry.html#Ext-dd.Registry" target="_blank">Ext.dd.Registry</a></h1></div><div id="docContent"><div id="doc-overview-content"><div class="lft"><p>Provides easy access to all drag drop components that are registered on a page.  Items can be retrieved either
directly by DOM node id, or by passing in the drag drop event that occurred and looking up the event target.</p>
<div class="members"><div class="m-methods"><a name="methods"></a><div class="definedBy">Defined By</div><h3 class="mth p">Methods</h3><div id="method-getHandle" class="member f ni"><a href="Ext.dd.Registry.html#method-getHandle" rel="method-getHandle" class="expand more ar"><span>&nbsp;</span></a><div class="title"><div class="meta"><a href="Ext.dd.Registry.html" class="definedIn docClass">Ext.dd.Registry</a><br/><a href="../source/Registry.html#Ext-dd.Registry-method-getHandle" class="viewSource">view source</a></div><a name="getHandle"></a><a name="method-getHandle"></a><a href="Ext.dd.Registry.html#" rel="method-getHandle" class="cls expand">getHandle</a>(
<span class="pre">String/HTMLElement id</span>)
 : Object</div><div class="description"><div class="short"><p>Returns the handle registered for a DOM Node by id</p>
</div><div class="long"><p>Returns the handle registered for a DOM Node by id</p>
<h3 class="pa">Parameters</h3><ul><li><span class="pre">id</span> : String/HTMLElement<div class="sub-desc"><p>The DOM node or id to look up</p>
</div></li></ul><h3 class="pa">Returns</h3><ul><li><span class="pre">Object</span>&nbsp; &nbsp;<p>handle The custom handle data</p>
</li></ul></div></div></div><div id="method-getHandleFromEvent" class="member ni"><a href="Ext.dd.Registry.html#method-getHandleFromEvent" rel="method-getHandleFromEvent" class="expand more ar"><span>&nbsp;</span></a><div class="title"><div class="meta"><a href="Ext.dd.Registry.html" class="definedIn docClass">Ext.dd.Registry</a><br/><a href="../source/Registry.html#Ext-dd.Registry-method-getHandleFromEvent" class="viewSource">view source</a></div><a name="getHandleFromEvent"></a><a name="method-getHandleFromEvent"></a><a href="Ext.dd.Registry.html#" rel="method-getHandleFromEvent" class="cls expand">getHandleFromEvent</a>(
<span class="pre">Event e</span>)
 : Object</div><div class="description"><div class="short"><p>Returns the handle that is registered for the DOM node that is the target of the event</p>
</div><div class="long"><p>Returns the handle that is registered for the DOM node that is the target of the event</p>
<h3 class="pa">Parameters</h3><ul><li><span class="pre">e</span> : Event<div class="sub-desc"><p>The event</p>
</div></li></ul><h3 class="pa">Returns</h3><ul><li><span class="pre">Object</span>&nbsp; &nbsp;<p>handle The custom handle data</p>
</li></ul></div></div></div><div id="method-getTarget" class="member ni"><a href="Ext.dd.Registry.html#method-getTarget" rel="method-getTarget" class="expand more ar"><span>&nbsp;</span></a><div class="title"><div class="meta"><a href="Ext.dd.Registry.html" class="definedIn docClass">Ext.dd.Registry</a><br/><a href="../source/Registry.html#Ext-dd.Registry-method-getTarget" class="viewSource">view source</a></div><a name="getTarget"></a><a name="method-getTarget"></a><a href="Ext.dd.Registry.html#" rel="method-getTarget" class="cls expand">getTarget</a>(
<span class="pre">String/HTMLElement id</span>)
 : Object</div><div class="description"><div class="short"><p>Returns a custom data object that is registered for a DOM node by id</p>
</div><div class="long"><p>Returns a custom data object that is registered for a DOM node by id</p>
<h3 class="pa">Parameters</h3><ul><li><span class="pre">id</span> : String/HTMLElement<div class="sub-desc"><p>The DOM node or id to look up</p>
</div></li></ul><h3 class="pa">Returns</h3><ul><li><span class="pre">Object</span>&nbsp; &nbsp;<p>data The custom data</p>
</li></ul></div></div></div><div id="method-getTargetFromEvent" class="member ni"><a href="Ext.dd.Registry.html#method-getTargetFromEvent" rel="method-getTargetFromEvent" class="expand more ar"><span>&nbsp;</span></a><div class="title"><div class="meta"><a href="Ext.dd.Registry.html" class="definedIn docClass">Ext.dd.Registry</a><br/><a href="../source/Registry.html#Ext-dd.Registry-method-getTargetFromEvent" class="viewSource">view source</a></div><a name="getTargetFromEvent"></a><a name="method-getTargetFromEvent"></a><a href="Ext.dd.Registry.html#" rel="method-getTargetFromEvent" class="cls expand">getTargetFromEvent</a>(
<span class="pre">Event e</span>)
 : Object</div><div class="description"><div class="short"><p>Returns a custom data object that is registered for the DOM node that is the target of the event</p>
</div><div class="long"><p>Returns a custom data object that is registered for the DOM node that is the target of the event</p>
<h3 class="pa">Parameters</h3><ul><li><span class="pre">e</span> : Event<div class="sub-desc"><p>The event</p>
</div></li></ul><h3 class="pa">Returns</h3><ul><li><span class="pre">Object</span>&nbsp; &nbsp;<p>data The custom data</p>
</li></ul></div></div></div><div id="method-register" class="member ni"><a href="Ext.dd.Registry.html#method-register" rel="method-register" class="expand more ar"><span>&nbsp;</span></a><div class="title"><div class="meta"><a href="Ext.dd.Registry.html" class="definedIn docClass">Ext.dd.Registry</a><br/><a href="../source/Registry.html#Ext-dd.Registry-method-register" class="viewSource">view source</a></div><a name="register"></a><a name="method-register"></a><a href="Ext.dd.Registry.html#" rel="method-register" class="cls expand">register</a>(
<span class="pre">String/HTMLElement element, [Object data]</span>)
 : void</div><div class="description"><div class="short"><p>Resgister a drag drop element</p>
</div><div class="long"><p>Resgister a drag drop element</p>
<h3 class="pa">Parameters</h3><ul><li><span class="pre">element</span> : String/HTMLElement<div class="sub-desc"><p>The id or DOM node to register</p>
</div></li><li><span class="pre">data</span> : Object<div class="sub-desc"><p>(optional) An custom data object that will be passed between the elements that are involved
in drag drop operations.  You can populate this object with any arbitrary properties that your own code
knows how to interpret, plus there are some specific properties known to the Registry that should be
populated in the data object (if applicable):</p>

<pre>Value      Description<br />
---------  ------------------------------------------<br />
handles    Array of DOM nodes that trigger dragging<br />
           for the element being registered<br />
isHandle   True if the element passed in triggers<br />
           dragging itself, else false
</pre>

</div></li></ul><h3 class="pa">Returns</h3><ul><li><span class="pre">void</span>&nbsp; &nbsp;
</li></ul></div></div></div><div id="method-unregister" class="member ni"><a href="Ext.dd.Registry.html#method-unregister" rel="method-unregister" class="expand more ar"><span>&nbsp;</span></a><div class="title"><div class="meta"><a href="Ext.dd.Registry.html" class="definedIn docClass">Ext.dd.Registry</a><br/><a href="../source/Registry.html#Ext-dd.Registry-method-unregister" class="viewSource">view source</a></div><a name="unregister"></a><a name="method-unregister"></a><a href="Ext.dd.Registry.html#" rel="method-unregister" class="cls expand">unregister</a>(
<span class="pre">String/HTMLElement element</span>)
 : void</div><div class="description"><div class="short"><p>Unregister a drag drop element</p>
</div><div class="long"><p>Unregister a drag drop element</p>
<h3 class="pa">Parameters</h3><ul><li><span class="pre">element</span> : String/HTMLElement<div class="sub-desc"><p>The id or DOM node to unregister</p>
</div></li></ul><h3 class="pa">Returns</h3><ul><li><span class="pre">void</span>&nbsp; &nbsp;
</li></ul></div></div></div></div></div></div></div><div id="pageContent"></div></div></div></div></body></html>